1 Public Class FrmPASSWORD
2     Private Sub TextBox1_KeyDown(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyEventArgs) Handles TextBox1.KeyDown
3         If e.KeyCode =
27 Then
4             Me.Close()
5         End If
6         If e.KeyCode =
13 Then
7             If TextBox1.Text =
"password" Then
8                 sqlSTR =
"UPDATE TBL_Stocks_Balances SET PASSWORD_INPUTED ='" & "Yes" & "' WHERE Item_ID =" & globalID
9                 ExecuteSQLQuery(sqlSTR)
10                 pass = True
11                 Audit_Trail(xUser_ID, TimeOfDay,
"Access to over-ride the critical of the product")
12                 xpass = True
13                 Me.Close()
14             Else
15                 MsgBox(
"Incorrect Password !!", MsgBoxStyle.Exclamation, "Sales and Inventory")
16             End If
17         End If
18     End Sub
19
20     Private Sub TextBox1_TextChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TextBox1.TextChanged
21
22     End Sub
23
24     Private Sub FrmPASSWORD_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
25         TextBox1.Text =
""
26     End Sub
27 End Class


Gõ tìm kiếm nhanh...